import java.util.ArrayList;
import java.util.PriorityQueue;
/**
 * Created with Intellij IDEA.
 * Description:
 * User:Lenovo
 * Date:2025-01-05
 * Time:7:18
 */
public class Text {
    public static void TestPriorityQueue(){
        PriorityQueue<Integer> q1 = new PriorityQueue<>();
        PriorityQueue<Integer> q2 = new PriorityQueue<>(100);
        ArrayList<Integer> list = new ArrayList<>();
        list.add(4);
        list.add(3);
        list.add(2);
        list.add(1);
        System.out.println(list.get(0));
        System.out.println(list.get(1));
        PriorityQueue<Integer> q3 = new PriorityQueue<>(list);
        System.out.println(q3.size());
        System.out.println(q3.peek());
    }
    public static void main(String[] args) {
        TestPriorityQueue();
    }
}
